import { getMembershipList, getmDetail } from "@/api/membershipList"
export default {
  namespaced: true, // 封闭
  state: {

  },
  mutations: {

  },
  getters: {

  },
  actions: {
    // 获取检测信息列表
    async fetchMembershipList(context, payload) {
      let { name, registered, perPage, page } = payload
      try {
        const { data } = await getMembershipList(name, registered, perPage, page)
        return data
      } catch (err) {
        console.log(err)
      }
    },
    // 获取活动列表详情
    async fetchmDetail(context, payload) {
      let { membershipId } = payload
      try {
        const { data } = await getmDetail(membershipId)
        return data
      } catch (err) {
        console.log(err)
      }
    },
  }
}
